package body Verem_Pkg is
   
   procedure Push(V: in out Verem; E: in Integer) is
   begin
      V.Elem(V.Elem_Szam):=E;
      V.Elem_Szam:=V.Elem_szam+1;
   end Push;
   
   procedure Pop(V: in out Verem) is 
   begin
      if (V.Elem_Szam/=0) then
            V.Elem_Szam:=V.Elem_Szam-1;
      end if;
   end Pop;
   
   function Top(V: Verem) return Integer is
   begin
      return V(V.Elem_Szam);
   end Top;

   function Is_Empty(V: Verem) return Boolean is 
   begin       return V.Elem_Szam=0;
   end Is_Empty;
   
end Verem_Pkg;
